import {request} from './request.js' //导入封装好的js文件
 
 /*登录接口*/
export function Login(data){
  return request({
    url:'/login',
    method:'post',
    data:data
  })
}
export function getCondition(){
  return request({
    url:'/member/getCondition',
    method:'get'
  })
}
/*新增会员*/
export function saveMember(data){
  return request({
    url:'/member/saveMember',
    method:'post',
    data
  })
}

/*查询会员*/
export function getMemberByOpenid(data){
  return request({
    url:'/member/getMemberByOpenid' ,
    method:'post',
	data
  })
}

/*新增职务*/
export function saveDuties(data){
  return request({
    url:'/duties/saveDuties',
    method:'post',
    data
  })
}
/*修改会员*/
export function modifyMember(data){
  return request({
    url:'/member/modifyMember',
    method:'post',
    data
  })
}
/*删除职务*/
export function delDuties(id){
  return request({
    url:'/duties/delDuties/' + id,
    method:'get',
  })
}
/*查询职务列表*/
export function dutiesList(data){
  return request({
    url:'/duties/dutiesList',
    method:'post',
    data
  })
}
/*会员列表*/
export function miniProgramList(data){
  return request({
    url:'/member/miniProgramList',
    method:'post',
    data
  })
}
/*浏览记录*/
export function addHistory(data){
  return request({
    url:'/member/addHistory',
    method:'post',
    data
  })
}
export function getMemberInfo(mid){
  return request({
    url:'/member/getMemberInfo/' + mid,
    method:'get',
  })
}
/*收藏，名片*/
export function collections(data){
  return request({
    url:'/member/collections',
    method:'post',
	data
  })
}
/*查询收藏列表*/
export function collectionsList(data){
  return request({
    url:'/member/collectionsList',
    method:'post',
	data
  })
}
/*取消收藏*/
export function cancelCollections(data){
  return request({
    url:'/member/cancelCollections',
    method:'post',
	data
  })
}
/*分享*/
export function getshare(data){
  return request({
    url:'/member/share',
    method:'post',
	data
  })
}
/*分享列表*/
export function shareList(data){
  return request({
    url:'/member/shareList',
    method:'post',
	data
  })
}

/*手机号*/
export function getPhone(data){
  return request({
    url:'/association/getPhone',
    method:'post',
	data
  })
}
/*浏览记录*/
export function historyList(data){
  return request({
    url:'/member/historyList',
    method:'post',
	data
  })
}
/*浏览记录*/
export function articlelist(data){
  return request({
    url:'/article/list',
    method:'post',
	data
  })
}
/*文章详情*/
export function articleByAid(data){
  return request({
    url:'/article/articleByAid',
    method:'post',
	data
  })
}
/*查询动态列表*/
export function trendslist(data){
  return request({
    url:'/trends/list',
    method:'post',
	data
  })
}
/*发布动态*/
export function trendsrelease(data){
  return request({
    url:'/trends/release',
    method:'post',
	data
  })
}
/*查询是否有未发布的动态*/
export function getTrendsid(mid){
  return request({
    url:'/trends/getTrends/' + mid,
    method:'get'
  })
}
/*点赞*/
export function likeOrCancelLike(data){
  return request({
    url:'/trends/likeOrCancelLike',
    method:'post',
	data
  })
}
/*清空草稿箱*/
export function removetid(tid){
  return request({
    url:'/trends/remove/' + tid,
    method:'get'
  })
}
/*查询活动详情*/
export function getByAid(aid){
  return request({
    url:'/activity/getByAid/' + aid,
    method:'get'
  })
}
/*点赞列表*/
export function likeList(data){
  return request({
    url:'/trends/likeList',
    method:'post',
	data
  })
}
/*点赞列表*/
export function miniGetByAid(data){
  return request({
    url:'/activity/miniGetByAid',
    method:'post',
	data
  })
}
/*查询活动列表*/
export function miniList(data){
  return request({
    url:'/activity/miniList',
    method:'post',
	data
  })
}
/*查询报名*/
export function enroll(data){
  return request({
    url:'/activity/enroll',
    method:'post',
	data
  })
}
/*查询报名列表*/
export function getMemberList(data){
  return request({
    url:'/activity/getMemberList',
    method:'post',
	data
  })
}
/*友好商协会列表*/
export function friendshiplist(data){
  return request({
    url:'/friendship/list',
    method:'post',
	data
  })
}
/*发布意见*/
export function opinionrelease(data){
  return request({
    url:'/opinion/release',
    method:'post',
	data
  })
}
/*首页接口*/
export function getHome(data){
  return request({
    url:'/association/home',
    method:'post',
    data
  })
}
/*友好商协会详情*/
export function getByFid(fid){
  return request({
    url:'/friendship/getByFid/' + fid,
    method:'get',
  })
}
/*协会简介*/
export function introduction(){
  return request({
    url:'/introduction/list',
    method:'get',
  })
}
/*首页接口*/
export function memberEnroll(data){
  return request({
    url:'/activity/memberEnroll',
    method:'post',
    data
  })
}
//动态分享
export function shareSquare(tid){
  return request({
    url:'/trends/share/'+tid,
    method:'get',
  })
}